import java.util.Scanner;

class Vehicle {
    private int passengers;
    private int fuelcap;
    private int mpg;

    public Vehicle(int passengers, int fuelcap, int mpg) {
        this.passengers = passengers;
        this.fuelcap = fuelcap;
        this.mpg = mpg;
    }

    public int getPassengers() {
        return passengers;
    }

    public void setPassengers(int passengers) {
        this.passengers = passengers;
    }

    public int getFuelCap() {
        return fuelcap;
    }

    public void setFuelCap(int fuelcap) {
        this.fuelcap = fuelcap;
    }

    public int getMPG() {
        return mpg;
    }

    public void setMPG(int mpg) {
        this.mpg = mpg;
    }

    public double range() {
        return fuelcap * mpg;
    }

    public double fuelneeded(int miles) {
        return miles / (double) mpg;
    }
}
class Truck extends Vehicle {
    private int cargocap;

    public Truck(int passengers, int fuelcap, int mpg, int cargocap) {
        super(passengers, fuelcap, mpg);
        this.cargocap = cargocap;
    }

    public int getCargo() {
        return cargocap;
    }

    public void setCargo(int cargocap) {
        this.cargocap = cargocap;
    }
}
public class Main11 {
    public static void main(String[] args) {
        Scanner in = new Scanner(System.in);
        int passengers = in.nextInt();
        int fuelcap = in.nextInt();
        int mpg = in.nextInt();
        int cargocap = in.nextInt();
        Truck t = new Truck(passengers, fuelcap, mpg, cargocap);
        int dist = in.nextInt();
        double gallons = t.fuelneeded(dist);
        System.out.println("Truck can carry " + t.getCargo() + " pounds.");
        System.out.println("To go " + dist + " miles truck needs " + gallons + " gallons of fuel.");
        in.close();
    }
}